<?php
function smarty_function_numberinput($params, $smarty) {
    $template = "numberinput.tpl";
    $inputparams = "";
    $classes = "";
    foreach ($params as $key=>$value) {
        if ($key == "class") { $classes = $value; }
        else {
            $inputparams .= "$key='$value' ";
        }
    }
    $smarty->assign("classes", $classes);
    $smarty->assign("params", $inputparams);
    return $smarty->fetch("plugins/$template");
}

?>
